<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@taglib uri="/unicall/taglib" prefix="cc" %>    
<%@ include file="../layout/main.jsp" %>
  <div id="wrapper">
  <div id="page-wrapper-inner" class="gray-bg dashbard-1">
   
   <div class="row wrapper white-bg page-heading">
      <!--   <div class="wrapper wrapper-content animated fadeInRight"> -->
            <div class="row">
                <div class="col-lg-12">
                <div class="ibox float-e-margins">
                    <div class="ibox-title">
                        <h5>SIP帐号信息</h5>
                        <div class="ibox-tools btn-group">
                           <a  href="javascript:query();" class="btn btn-primary" role="button">查询</a>
                        </div>
                    </div>
                    <div class="ibox-content">
                     <div class="row search-box">
                     <f:form action="account" modelAttribute="query" method="get" id="queryForm" cssClass="form-horizontal search-form">
                              <div class="form-group form-inline col-md-4">
                                <label>帐号：</label>
                                <f:input path="clientNumber" cssClass="form-control"/>
                              </div>
                              
                                <div class="form-group form-inline col-md-4">
                                <label>坐席：</label>
                                <f:input path="agentId" cssClass="form-control"/>
                              </div>
                             
                     </f:form>
                    </div>
                   

                    <div class="table-responsive">
                    <table class="table table-striped table-bordered table-hover dataTables-example" >
                    <thead>
                    <tr>
                        <th>帐号</th>
                        <th>密码</th>
                        <th>绑定坐席</th>
                        <th>操作</th>
                    </tr>
                    </thead>
                    <tbody>
                        <c:forEach items="${page.getContent()}" var="vo">
                        <tr>
                            <td>${vo.clientNumber }</td>
                            <td>${vo.password }</td>
                            <td>${vo.agentId }</td>
                            <td>
                                <a data-url="account/${vo.id}"  class="fa fa-search" data-func="showDetail" data-toggle="modal" data-target="#mainDialog" title="查看"></a>
                                <a href="account/${vo.id}/edit" class="fa fa-edit" title="编辑"></a>
                                <a href="javascript:;" data-url="account/${vo.id}" class="fa fa-trash-o" data-func="delete" title="删除"></a>
                                
                            </td>
                            </tr>
                        </c:forEach>
                        <c:if test="${empty page.getContent()}">
                           <tr class="empty-line"><td colspan="10">暂无记录</td></tr>
                        </c:if>
                        
                       </tbody>
                    </table>
                            <cc:pagination page="${page }" url="account"/>
                        </div>

                    </div>
                </div>
            </div>
            </div>
        </div>
           <script type="text/javascript">
            function query(){
                $('#queryForm').submit();
            }
           </script>
            </div>
        </div>
    